package com.exchange.controller;

import com.exchange.service.StarsAddressService;
import com.exchange.until.Result;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestHeader;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("stars")
@Tag(name = "收藏地址")
public class StarsController {

    @Autowired
    private StarsAddressService starsAddressService;

    @GetMapping("/mystars")
    @Operation(summary = "我的地址收藏")
    public Result mystars(@RequestHeader("token")String token) {
     return new Result<>(200,"ok",true,starsAddressService.mystars(token));
    }
}
